<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ include file="../../common/common_taglib.jsp"%>

<%
    String actionURL = request.getContextPath() + "/ets/user/doQuery.do";
%>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
	<head>
		<%@include file="../../common/common_head.jsp"%>
	</head>
<body
	onload="MM_preloadImages('<%=request.getContextPath()%>/images/btnoneone.png','<%=request.getContextPath()%>/images/btntwotwo.png','<%=request.getContextPath()%>/images/btnsixsix.png','<%=request.getContextPath()%>/images/btnsevenseven.png')">
	<div class="right">
		<div class="rightheader">
			<span class="subnav">当前位置：<a href="#">系统管理</a>&gt;&gt;<a
				href="#">用户管理</a> </span>
		</div>
		<div class="mainbtn">
			<table width="100%" border="0" cellspacing="0" class="search">
				<tr>
					<td width="8%" align="left"><a href="javascript:void(0);"
						onclick="$.toAddDiag(600,320,'新增用户信息','toAdd.do')"
						onmouseout="MM_swapImgRestore()"
						onmouseover="MM_swapImage('Image5','','<%=request.getContextPath()%>/images/btnsixsix.png',1)"><img
							src="<%=request.getContextPath()%>/images/btnsix.png" name="Image5" width="67" height="26"
							border="0" id="Image5" /> </a></td>
					<td width="9%" align="left"><a href="javascript:void(0);"
						onclick="confirmDel(document);" onmouseout="MM_swapImgRestore()"
						onmouseover="MM_swapImage('Image6','','images/btnsevenseven.png',1)"><img
							src="<%=request.getContextPath()%>/images/btnseven.png" name="Image6" width="67" height="26"
							border="0" id="Image6" /> </a></td>
					<td width="47%" align="right">查询条件：</td>
					<td width="7%" align="center"><select name="" class="inputone"
						id="queryCondition_key">
							<option value="userName">用户名</option>
					</select></td>
					<td width="16%" align="center"><input class="inputtext"
						id="queryCondition_value" name="" type="text" value="" /></td>
					<td width="6%" align="center"><a href="javascript:do_search(1);"
						onmouseout="MM_swapImgRestore()"
						onmouseover="MM_swapImage('Image3','','<%=request.getContextPath()%>/images/btnoneone.png',1)"><img
							src="<%=request.getContextPath()%>/images/btnone.png" name="Image3" width="67" height="26"
							border="0" id="Image3" /> </a></td>
					<td width="7%" align="center"><a href="#"
						onmouseout="MM_swapImgRestore()"
						onmouseover="MM_swapImage('Image4','','<%=request.getContextPath()%>/images/btntwotwo.png',1)"><img
							src="<%=request.getContextPath()%>/images/btntwo.png" name="Image4" width="85" height="26"
							border="0" id="Image4" /> </a></td>
				</tr>
			</table>


		</div>
		<div class="righttd">
			<form name="form_del" id="form_del" target="hid"
				action="ets/user/doDel.do">
				<table width="100%" border="0" cellspacing="0" class="maintd">
					<tr>
						<th scope="col"><input type="checkbox" name="checkbox"
							id="checkbox" onclick="selectAll('form_del','innerIndexs');" />
						</th>
						<th scope="col">序号</th>
						<th scope="col">用户名</th>
						<th scope="col">密码</th>
						<th scope="col">角色</th>
						<th scope="col">用户状态</th>
						<th scope="col">创建时间</th>
						<th scope="col">操作</th>
					</tr>

					<!-- 记录为空 -->
					<s:if test=" results.size == 0">
					</s:if>
					<!-- 存在记录 -->
					<s:if test=" results.size > 0">
						<!--显示List记录！-->
						<s:iterator value="results" status="s">
							<tr>
								<td><input type="checkbox" name="innerIndexs"
									id="innerIndexs"
									value='<s:property value="results[#s.index].userId"/>' />
								</td>
								<td><s:property value="#s.index+1" />
								</td>
								<td><a href="javascript:void(0);" onclick="$.toDetailDiag(500,388,'查看用户信息','toDetail.do?innerIndex=<s:property value="results[#s.index].userId"/>')"><s:property value="results[#s.index].userName" /></a>
								</td>
								<td><s:property value="results[#s.index].password" />
								</td>
								<td><s:property value="results[#s.index].roleInfo.roleName" />
								</td>
								<td><s:if test='status == 0'>停用</s:if> <s:if
										test='status == 1'>启用</s:if>
								</td>
								<td><s:date name="createTime" />
								</td>
								<td width="25%">
									<a href="javascript:void(0);"
										onclick="$.toModDiag(500,388,'修改用户信息','toMod.do?innerIndex=<s:property value="results[#s.index].userId"/>')">修改</a>
								</td>
							</tr>
						</s:iterator>
					</s:if>
				</table>
			</form>
		</div>
	</div>
	
	<form name="pages" method="post">
		<!--隐藏域 Start -->
		<!-- 引入分页和排序 -->
		<div>
			<input id="curPage" type="hidden" name="page.curPage"
				value="<s:property value='page.curPage'/>" /> <input
				id="numPerPage" type="hidden" name="page.numPerPage"
				value="<s:property value='page.numPerPage'/>" /> <input
				type="hidden" id="queryCondition_key_hidden" name="queryCondition.key"
				value="<s:property value='queryCondition.key'/>" /> <input
				id="queryCondition_value_hidden" type="hidden"
				name="queryCondition.value"
				value="<s:property value='queryCondition.value'/>" />
			<iframe name="hid" id="hid" src="" height="0px"></iframe>
		</div>
		<!--隐藏域 End-->
		<div <s:if test=" results.size == 0">style="display:none "</s:if>>
			<%@include file="/jsp/ets/common/page.txt"%>
		</div>
	</form>
</body>
</html>
